<div id="global">
	<?php require_once '/template/left-sidebar.phtml';?>
	<div id="content-with-twoside">
		<div class="global-border">
			<h1><span><?php echo $this->escape($this->title);?></span></h1>
			<div class="global-content">
				<table>
					<tr>
						<td></td>
						<td></td>
						<td style="width: 120px;"><b><?php echo $this->escape($this->username);?></b></td>
						<td style="width: 60px;"><b><?php echo $this->escape($this->credit);?></b></td>
						<td style="width: 60px;"><b><?php echo $this->escape($this->mark);?></b></td>
						<td style="width: 150px;"><b><?php echo $this->escape($this->lastTrade);?></b></td>
						<td style="width: 150px;"><b><?php echo $this->escape($this->creationDate);?></b></td>
					</tr>
					<?php 
					$mbm_mapper = new Application_Model_MemberMapper();
					for($i=0; $i<sizeof($this->relationEntries); $i++){
						$mbmEntry = $mbm_mapper->findByMemberId($this->relationEntries[$i]->specific_mbm_id);
					?>
						<tr>
							<td>
								<form id="deleteRelationForm<?php echo $this->relationEntries[$i]->relation_id?>" method='post' 
									action='<?php echo $this->escape($this->action) . $this->relationEntries[$i]->relation_id;?>' enctype='multipart/form-data'>
									<input id="btnDelete<?php echo $this->relationEntries[$i]->relation_id;?>" class="btnDeleteRelation" 
										type="submit" value="<?php echo $this->escape($this->delete);?>">
								</form>
							</td>
							<td><img width="50px" height="50px" src="<?php echo $mbmEntry[0]->image;?>"/></td>
							<td>
								<a href="<?php echo $this->escape($this->profileAction) . $mbmEntry[0]->member_id;?>"><?php echo $mbmEntry[0]->username;?></a>
							</td>
							<td><?php echo $mbmEntry[0]->deal_credit;?></td>
							<td><?php echo $mbmEntry[0]->rating_credit;?></td>
							<td></td>
							<td><?php echo $this->relationEntries[$i]->creation_time;?></td>
							
						</tr>
					<?php 
					}
					?>
				</table>
			</div>
		</div>
	</div>
	<?php require_once '/template/right-sidebar.phtml';?>
</div>